/**
 * 
 */
package com.dp.behav.state;

/**
 * @author Sunaina.Sharma
 * 
 *         The Context can have a number of internal States, whenever the
 *         request() method is called on the Context, the message is delegated
 *         to the State to handle
 * 
 */
public class MP3PlayerContext {

	private State state;

	/**
	 * @param state
	 */
	MP3PlayerContext(State state) {
		this.state = state;
	}

	/**
	 * 
	 */
	public void play() {
		state.pressPlay(this);
	}

	/**
	 * @param state
	 */
	public void setState(State state) {
		this.state = state;
	}

	/**
	 * @return
	 */
	public State getState() {
		return state;
	}

}
